Working modes of an automatic (auto) focus system of a modern camera are mainly classified into single auto focus, continuous auto focus, and intelligent auto focus.
A working process of single auto focus is enabled by half-pressing a shutter, and a focus process continues before a focus is focused accurately. After a processor considers that the focus is accurate, as long as the shutter is fully pressed, a shooting process is completed. At the same time, the auto focus system stops working. If an object to be shot or a camera moves before the shutter is fully pressed and after an alert tone is played upon focus completion, an unclear picture may be seen after the shutter is fully pressed because “single” auto focus is used. Due to its characteristics, single auto focus is the best choice when a stationary object is shot (for example, scenery, macrophotography, and figure group photo).
Unlike single auto focus, for continuous auto focus, after a processor “considers” that a focus is accurate, an auto focus system keeps working and the focus is not locked, an objective of which lies in that when an object to be shot moves, the auto focus system is capable of driving a lens to adjust in real time according to a change of the focus, thereby always keeping an object to be shot in a clear state. Certainly, a focus frame of a camera also needs to accurately focus on an object to be shot in real time. Continuous auto focus is mostly used for shooting an object in motion, such as shooting a sportsperson in a sports game, shooting a spokesperson in a press conference, and capturing a wonderful moment of an animal in motion.
Intelligent auto focus works in a manner of combining single auto focus and continuous auto focus, which automatically selects a focus manner according to a movement speed of an object to be shot. An internal ranging component constantly measures an image within an automatic focus area, and transmits to a processor in real time. Single auto focus is selected when an object to be shot is stationary while continuous auto focus is selected when an object to be shot is in motion. Because a switching task is performed by the processor, a user only needs to press a shutter.
With the rapid development of a terminal device, at present, many handheld devices such as a mobile phone and a tablet computer integrate a camera module and provide an auto focus function. Generally, single auto focus is adopted due to power consumption, cost, and other reasons. However, for single auto focus, an auto focus process needs to be completed before a photo is taken each time, which therefore causes a time for taking a photo (auto focus time plus shooting time: Tf+Ts) to be too long. In order to accelerate a shooting speed, some terminal vendors use a location detection sensor (for example, gravity sensor) of a device to detect whether a shift occurs on a device. If a movement occurs on a device, an auto focus process is re-initiated. Therefore, when a user presses a shutter to take a photo, a camera is in a focus state or in a focus process. If the camera is in a focus process, wait until the focus is completed, and a photo may be taken with an entire shooting time Tf′+Ts (0≦Tf′<Tf), which, to a certain extent, shortens the shooting time. This method for detecting a device shift by using a sensor may constantly detect whether a shift occurs on a device. With constant movement of the device, the auto focus process is also constantly initiated, which looks like continuous auto focus; however, its working principle is different from that of continuous auto focus, and may be referred to as pseudo continuous auto focus. Another advantage of adopting this auto focus manner is that a clear image may be obtained in a preview state of a camera.
Although this pseudo continuous auto focus mode may shorten the entire shooting time to a certain extent and obtain a clear image in the preview state of the camera, it also has some shortcomings. When a device is in a dim light environment, it is necessary to fill light with the help of a camera flash in order to ensure successful focus, which is generally referred to as preflashing. In this way, when the device constantly moves, the camera flash ceaselessly preflashes because auto focus is continually initiated, which brings inconvenience to a user. At present, there is an approach, which is to directly close the camera flash; however, in this case, problems that focus fails in a dim light environment and a photo taken is unclear are caused. Therefore, how to effectively determine a focus mode of a terminal becomes an urgent technical problem to be solved.